CTimeSpan Comparison Operators

BOOL operator ==( CTimeSpan timeSpan ) const;
BOOL operator !=( CTimeSpan timeSpan ) const;
BOOL operator <( CTimeSpan timeSpan ) const;
BOOL operator >( CTimeSpan timeSpan ) const;
BOOL operator <=( CTimeSpan timeSpan ) const;
BOOL operator >=( CTimeSpan timeSpan ) const;

说明:
这些操作符比较两个相对时间值。如果测试条件为真,则返回非零值;否则返回0。

示例:
// example for CTimeSpan comparison operatorsCTimeSpan ts1( 100 );
CTimeSpan ts2( 110 );
ATLASSERT( ( ts1 != ts2 ) && ( ts1 < ts2 ) && ( ts1 <= ts2 ) );